package BookManager.operation;

import BookManager.BookDao;

import java.util.Scanner;

public class DeleteOperation implements IOperation {
    @Override
    public void work() {
        Scanner scanner=new Scanner(System.in);
        int bookId=scanner.nextInt();
        BookDao bookDao=new BookDao();
        boolean bool=bookDao.delete(bookId);
        if(bool){
            System.out.println("删除成功");
        }else{
            System.out.println("删除失败");
        }
    }
}
